package com.xli.mis.datasource.mapper;

import com.xli.mis.datasource.entity.DataSource;
import com.xli.mis.datasource.entity.DataSourceCache;
import org.mapstruct.Mapper;
import org.mapstruct.ReportingPolicy;
import org.mapstruct.factory.Mappers;

import java.util.List;

@Mapper(unmappedTargetPolicy = ReportingPolicy.IGNORE)
public interface IDataSourceCacheMapper {

    IDataSourceCacheMapper INSTANCE = Mappers.getMapper(IDataSourceCacheMapper.class);

    DataSourceCache toCacheEntity(DataSource dataSource);

    List<DataSourceCache> toCacheList(List<DataSource> dataSourceList);

    List<DataSource> toEntityList(List<DataSourceCache> dataSourceCacheList);
}
